using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace WorkFlowCore.BusinessDemo.Web.Models
{
    public class UserDetailViewModel
    {
        public int Id { get; set; }

        [Display(Name = "姓名")]
        public string Name { get; set; }

        [Display(Name = "工号")]
        public string EmployeeNumber { get; set; }

        [Display(Name = "电话")]
        public string Phone { get; set; }

        [Display(Name = "邮箱")]
        [EmailAddress]
        public string Email { get; set; }

        [Display(Name = "性别")]
        public int Gender { get; set; }

        [Display(Name = "出生日期")]
        [DataType(DataType.Date)]
        public DateTime? BirthDate { get; set; }

        [Display(Name = "户籍地")]
        public string Hometown { get; set; }

        public List<RoleInfo> Roles { get; set; } = new List<RoleInfo>();

        public class RoleInfo
        {
            public int Id { get; set; }
            public string Name { get; set; }
        }
    }
}
